package com.mycom.service.impl;

import com.mycom.dao.TeamWaitCertainDao;
import com.mycom.pojo.TeamWaitCertain;
import com.mycom.service.TeamWaitCertainService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TeamWaitCertainServiceImpl implements TeamWaitCertainService {
    @Autowired
    private TeamWaitCertainDao teamWaitCertainDao;

    @Override
    public boolean save(TeamWaitCertain teamWaitCertain) {
        return teamWaitCertainDao.save(teamWaitCertain) > 0 ? true : false;
    }

    public List<TeamWaitCertain> findByFormId(Integer formId){
        return teamWaitCertainDao.findByFormId(formId);
    }

    public boolean deleteByFormId(Integer formId){
        return teamWaitCertainDao.deleteByFormId(formId) >=0 ? true : false;
    }
}
